package com.huike.report.domain.service.impl;

import com.huike.business.domain.TbBusiness;
import com.huike.common.core.page.PageResult;
import com.huike.common.utils.SecurityUtils;
import com.huike.report.domain.mapper.ReporterMapper;
import com.huike.report.domain.service.IndexService;
import com.huike.report.domain.vo.IndexTodayInfoVO;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class IndexServiceImpl implements IndexService {
    @Resource
    private ReporterMapper reporterMapper;

//    @Override
//    public IndexTodayInfoVO getBaseInfo(String beginCreateTime, String endCreateTime) {
//        IndexTodayInfoVO indexTodayInfoVO = new IndexTodayInfoVO();
//        String userName = SecurityUtils.getUsername();
//        indexTodayInfoVO.setTodayBusinessNum(reporterMapper.getBusinessNum(beginCreateTime, endCreateTime, userName));
//        indexTodayInfoVO.setTodaySalesAmount(reporterMapper.getSalesAmount(beginCreateTime, endCreateTime, userName));
//        indexTodayInfoVO.setTodayCluesNum(reporterMapper.getCluesNum(beginCreateTime, endCreateTime, userName));
//        indexTodayInfoVO.setTodayContractNum(reporterMapper.getContractNum(beginCreateTime, endCreateTime, userName));
//        return indexTodayInfoVO;
//
//    }

    @Override
    public List<TbBusiness> selectUserList(TbBusiness user) {
        return reporterMapper.contractStatisticsList(user);
    }

}
